package com.javasm.mingming.adminuser.entity;

import java.util.Date;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import java.io.Serializable;
import java.util.List;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.annotation.Resource;

/**
 * 后台用户(AdminUser)表实体类
 *
 * @author makejava
 * @since 2025-01-11 09:51:34
 */
@SuppressWarnings("serial")
@Data
@NoArgsConstructor
@AllArgsConstructor
public class AdminUser extends Model<AdminUser> {
    @TableId(type = IdType.AUTO)
    private Long uid;
    //用户名
    private String username;
    //密码
    private String password;
    //角色id
    private Long roleId;
    //注册时间
    private Date regTime;
    //登录时间
    private Date loginTime;
    //=1有效 =0无效
    private Integer isvalid;
    //创建人
    private Long createUid;
    //备注
    private String remark;
    
    private String headImg;

    private String phone;

    @TableField(exist = false)
    private String code;
    //用户和角色的关系,一对一
    @TableField(exist = false)
    private AdminRole adminRole;

    @TableField(exist = false)
    private List<AdminAuthority> authorityList;

}

